Skip to content

Conversation

@antareepsarkar
Copy link

@antareepsarkar antareepsarkar commented Nov 22, 2025

It follows from #63058

@antareepsarkar
Copy link
Author

@rhshadrach @Alvaro-Kothe
Please review this.

Comment on lines +325 to +328
if dtype == StringDtype() and isinstance(data, (list, tuple)):
for i in data:
if isinstance(i, (list, tuple, np.ndarray)):
raise TypeError("Values must be a 1D list-like")
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This check seems extremely expensive for an edge case. Maybe it's possible to patch the function that performs the conversion in _from_sequence.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

BUG: pandas.array works fine when 2-D array contains string

2 participants